﻿using System;

class SquenceOfEqualElements
{
    static void Main()
    {
        Console.Write("How long will be your array : ");
        int n = int.Parse(Console.ReadLine());
        int[] Array = new int[n];
        Console.WriteLine("Insert {0} integer" , n);
        for (int i = 0; i < Array.Length; i++)
        {
            Console.Write("{0}:" , i+1);
            Array[i] = int.Parse(Console.ReadLine());
        }
        int count = 1;
        int BiggestSequence = 0;
        int BiggestSequenceIndex = 0;
        for (int j = 0; j < Array.Length-1; j++)
        {
            if (Array[j] == Array[j + 1])
            {
                count++;
                if (count > BiggestSequence)
                {
                    BiggestSequence = count;
                    BiggestSequenceIndex = j;
                }
            }
            else
            {
                count = 1;
            }

        }
        if (BiggestSequence > 1)
        {
            Console.WriteLine("Biggest Sequence is from {0} intergers with value {1}", BiggestSequence, Array[BiggestSequenceIndex]);
        }
        else
        {
            Console.WriteLine("There is no sequence of equal elements");
        }
    }
}
